<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<!DOCTYPE html>
<html>
<head lang="en">
    <meta charset="UTF-8">
    <title>佐心，教家长做父母</title>
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="apple-mobile-web-app-status-bar-style" content="black">
    <meta name="format-detection" content="telephone=no">
	<c:set var="ctx" value="${pageContext.request.contextPath}" />
    <link rel="stylesheet" href="${ctx}/assets/css/amazeui.min.css">
    <link rel="stylesheet" href="${ctx}/assets/css/style.css?v=2.3">
    <link rel="stylesheet" href="${ctx}/assets/css/index.css?v=2.3">
    <script src="${ctx}/assets/js/myAlert.js"></script>
</head>
<body class="bg-white">
<header data-am-widget="header" class="am-header am-header-default am-header-fixed am-border-bottom">
    <div class="am-header-left am-header-nav">
        <a onclick="history.go(-1)"> <i class="icon_8"></i>
        </a>
    </div>
    <h1 class="am-header-title">
    <c:if test="${flag==9}">
    	家长成熟度
    </c:if>
    <c:if test="${flag!=9}">
    	在线评估
    </c:if>
    </h1>

    <div class="am-header-right am-header-nav">
        <a  id="btnfeedback">
         <i class="icon_63"></i>
        </a>
    </div>
</header>
<section class="am-padding-bottom-sm" id="amz-main" data-tag="css-nav">

    <div class="box am-padding-left-lg am-padding-right-lg margin-top-20">
        <div class="width-60px">
            <div class="icon_031"></div>
        </div>
        <div class="box-1">
            <div class="icon_64 am-text-center font-color-white">想知道你的心理情况?</div>
        </div>
    </div>

    <div class="bg-white padding-top-35 am-container am-padding-bottom-sm ">
        <div class="am-margin-top-sm prelative">
            <div class="icon_62 am-text-center font-color-white">
                    <div class="font-12">评估人数</div>
                    <div>${pinggu.pingguCount}</div>
            </div>
            <div class="am-container bg-gray-2 font-14 font-color-13 padding-top-35 am-padding-bottom-sm border-1">
                ${pinggu.pingguMark}
            </div>

        </div>

        <div class="am-margin-top-sm btn-7" onclick="window.location.href='pinggu/zaixianPinggu.jsp?flag=${pinggu.id}'">
            开始评估
        </div>

    </div>


</section>

<div class="am-modal am-modal-prompt" tabindex="-1" id="my-prompt">
    <div class="am-modal-dialog">
        <div class="am-modal-hd">问题反馈</div>
        <div class="am-modal-bd">
            <textarea rows="3" class="mark_content am-modal-prompt-input"  placeholder="对本产品有什么建议，敬请告知，谢谢！"></textarea>
        </div>
        <div class="am-modal-footer">
            <span class="am-modal-btn" data-am-modal-cancel>取消</span>
            <span class="am-modal-btn" data-am-modal-confirm>提交</span>
        </div>
    </div>
</div>

<script src="${ctx}/assets/js/jquery.min.js"></script>
<script src="${ctx}/assets/js/amazeui.min.js"></script>
<script>
    $(function () {
        $('#btnfeedback').on('click', function () {
            $('#my-prompt').modal({
                relatedTarget: this,
                onConfirm: function (e) {
                    if(""==e.data){
                		myAlert("请输入意见或建议，谢谢");
                		return false;
                	}
                    var gotoTuCao=$.ajax({url:"${ctx}/gotoTuCao?content="+e.data,async:false});
				    var gotoTuCaoJson=JSON.parse(gotoTuCao.responseText);
				    if(gotoTuCaoJson.resultCode=="0"){
				    	myAlert("感谢您的热心回馈，谢谢");
				    }
                },
                onCancel: function (e) {
//                    alert('不想说!');
                }
            });
        });

        $("#shouchang").on('click', function () {
            if ($(this).find("i.icon_48").hasClass("cur")) {
                $(this).find("i.icon_48").removeClass("cur");
            } else {
                $(this).find("i.icon_48").addClass("cur");
            }
        });
    });
</script>
</body>
</html>